import {lazy} from "react";
import {Navigate} from "react-router-dom";


const AddUser = lazy(() => import("./AddUser"))
const UserData = lazy(() => import("./UserData"))
const UserList = lazy(() => import("./UserList"))


export default [
  // 主页面路由
  {
    path: "/main/user", children: [
      {path: "/main/user", element: <Navigate replace to="/main/user/userList"/>},
      {path: "/main/user/userList", element: <UserList/>},
      {path: "/main/user/addUser", element: <AddUser/>},
      {path: "/main/user/userData", element: <UserData/>}
    ]
  },
]